package org.example.admin.mapper;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.example.admin.entity.Shop;

import java.util.List;

@Mapper
public interface ShopMapper {

    int insertShop(
            @Param("dishname") String dishname,
            @Param("dishprice") int dishprice,
            @Param("userid") int userid,
            @Param("number") int number
    );
    List<Shop> selectShopByUserId(int userId);

    int updateNumber(@Param("number") int number,
                     @Param("shopid") int shopid);

    Shop selectShopByShopId(int shopid);

    int deleteShopByShopId(int shopid);
}
